home *** CD-ROM | disk | FTP | other *** search
/ Sprite 1984 - 1993 / Sprite 1984 - 1993.iso / src / boot / scsiDiskBoot / sun3.md / devConfig.c.strip < prev    next >
Encoding:
Text File  |  1989-06-10  |  2.5 KB  |  96 lines

  1. /* 
  2.  * devConfig.c --
  3.  *
  4.  *    Configuration table for the devices in the system.  There is
  5.  *    a table for the possible controllers in the system, and
  6.  *    then a table for devices.  Devices are implicitly associated
  7.  *    with a controller.  This file should be automatically generated
  8.  *    by a config program, but it isn't.
  9.  *
  10.  * Copyright 1986 Regents of the University of California
  11.  * All rights reserved.
  12.  */
  13.  
  14. #ifndef lint
  15. static char rcsid[] = "$Header: /sprite/src/kernel/dev/sun3.md/RCS/devConfig.c,v 8.6 89/05/24 07:50:35 rab Exp $ SPRITE (Berkeley)";
  16. #endif not lint
  17.  
  18.  
  19. #include "sprite.h"
  20. #include "boot.h"
  21. #include "devInt.h"
  22. #include "devTypesInt.h"
  23. #include "fs.h"
  24.  
  25. /*
  26.  * Per device include files.
  27.  */
  28. #if defined(SCSI_DISK_BOOT) || defined(SCSI_TAPE_BOOT)
  29. #include "scsiHBA.h"
  30. #ifdef SCSI3_BOOT
  31. #include "scsi3.h"
  32. #endif
  33. #ifdef SCSI0_BOOT
  34. #include "scsi0.h"
  35. #endif
  36. #endif
  37. #ifdef XYLOGICS_BOOT
  38. #include "xylogics450.h"
  39. #endif
  40.  
  41. /*
  42.  * The controller configuration table.
  43.  */
  44. DevConfigController devCntrlr[] = {
  45.    /* Name     Address,  Addr space, ID, InitProc   IntrVector  IntrRoutine. */
  46. #ifdef SCSI3_BOOT
  47.     { "SCSI3", 0x0FE12000,    DEV_OBIO,  0, DevSCSI3Init,26, DevSCSI3Intr },
  48.     { "SCSI3",  0x200000, DEV_VME_D16A24, 0, DevSCSI3Init, 64, DevSCSI3Intr },
  49. #endif
  50. #ifdef SCSI0_BOOT
  51.     { "SCSI0",  0x200000, DEV_VME_D16A24, 0, DevSCSI0Init, 64, DevSCSI0Intr },
  52. #endif
  53. #ifdef XYLOGICS_BOOT
  54.     { "Xylogics450", 0xee40, DEV_VME_D16A16,     0, DevXylogics450Init,
  55. #endif
  56.  
  57. };
  58. int devNumConfigCntrlrs = sizeof(devCntrlr) / sizeof(DevConfigController);
  59.  
  60. /*
  61.  * Table of SCSI HBA types attached to this system.
  62.  */
  63.  
  64. ScsiDevice *((*devScsiAttachProcs[])()) = {
  65. #ifdef SCSI3_BOOT
  66.     DevSCSI3AttachDevice,        /* SCSI Controller type 0. */
  67. #endif
  68. #ifdef SCSI0_BOOT
  69.     DevSCSI0AttachDevice,        /* SCSI Controller type 1. */
  70. #endif
  71. };
  72. int devScsiNumHBATypes = sizeof(devScsiAttachProcs) / 
  73.              sizeof(devScsiAttachProcs[0]);
  74.  
  75. /*
  76.  * A list of disk devices that is used when probing for a root partition.
  77.  * The choices are:
  78.  * Drive 0 partition 0 of xylogics 450 controller 0.
  79.  * SCSI Disk target ID 0 LUN 0 partition 0 on SCSI0 HBA 0.
  80.  * SCSI Disk target ID 0 LUN 0 partition 0 on SCSI3 HBA 0. 
  81.  */
  82. Fs_Device devFsDefaultDiskPartitions[] = { 
  83. #ifdef XYLOGICS_BOOT
  84.     { -1, DEV_XYLOGICS, 0, (ClientData) NIL },    
  85. #endif
  86. #if defined(SCSI0_BOOT) || defined(SCSI3_BOOT)
  87.     { -1, SCSI_MAKE_DEVICE_TYPE(DEV_SCSI_DISK, 0, 0, 0, 0, 0),
  88.       SCSI_MAKE_DEVICE_UNIT(DEV_SCSI_DISK, 0, 0, 0, 0, 0),
  89.         (ClientData) NIL }, 
  90. #endif
  91. };
  92. int devNumDefaultDiskPartitions = sizeof(devFsDefaultDiskPartitions) / 
  93.               sizeof(Fs_Device);
  94.  
  95.  
  96.